function get(id){

    return document.getElementById(id)


}

var header= get("header")
main=get("nav")
//alert(header)

var li=get("header").getElementsByTagName("a")
// alert(li.length)
var divs=get("nav").getElementsByTagName("section")
// alert(divs.length)


for(var i=0; i<li.length; i++){

    li[i].id=i
    //onmouseover
    li[i].onclick=function(){

        var that=this
        setTimeout(function(){
            for(var j=0; j<li.length; j++){


                divs[j].style.display="none"
            }






            divs[that.id].style.display="block"

        },500);

    }

}